package com.example.demo.mapper;

import com.example.demo.entity.Category;
import org.apache.ibatis.annotations.Mapper;

import java.util.List;


/**
 * categoryMapper接口
 * 
 * @author ruoyi
 * @date 2025-04-01
 */
@Mapper
public interface CategoryMapper
{
    /**
     * 查询category
     * 
     * @param cid category主键
     * @return category
     */
    public Category selectCategoryByCid(Long cid);

    /**
     * 查询category列表
     * 
     * @param category category
     * @return category集合
     */
    public List<Category> selectCategoryList(Category category);
    public List<Category> selectCategoryGoodsList(Category category);
    /**
     * 新增category
     * 
     * @param category category
     * @return 结果
     */
    public int insertCategory(Category category);

    /**
     * 修改category
     * 
     * @param category category
     * @return 结果
     */
    public int updateCategory(Category category);

    /**
     * 删除category
     * 
     * @param cid category主键
     * @return 结果
     */
    public int deleteCategoryByCid(Long cid);

    /**
     * 批量删除category
     * 
     * @param cids 需要删除的数据主键集合
     * @return 结果
     */
    public int deleteCategoryByCids(Long[] cids);
}
